home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 January: Mac OS SDK / Dev.CD Jan 97 SDK2.toast / Development Kits (Disc 2) / OpenDoc International / Development / TSMTEsample⁄1.1 / Source / tsmUtl.h < prev   
Encoding:
C/C++ Source or Header  |  1996-11-14  |  2.2 KB  |  135 lines  |  [TEXT/CWIE]

  1. #ifndef __tsmUtl__   
  2. #define __tsmUtl__ 
  3. #endif
  4.  
  5. // -- TSMTEsample Includes --
  6.  
  7. #ifndef _SAMPLEPARTUTILS_
  8. #include "SamplePartUtils.h"
  9. #endif
  10.  
  11. #ifndef _OD_SHARETSM_   
  12. #include "ShareTSM.h"
  13. #endif
  14.  
  15. #ifndef __TSMTE__   
  16. #include "TSMTE.h"
  17. #endif
  18.  
  19. // -- OpenDoc Includes --
  20.  
  21. #ifndef _ODTYPES_
  22. #include <ODTypes.h>
  23. #endif
  24.  
  25. #ifndef SOM_ODPart_xh
  26. #include <Part.xh>
  27. #endif
  28.  
  29. #ifndef SOM_ODFacet_xh
  30. #include <Facet.xh>
  31. #endif
  32.  
  33. #ifndef SOM_ODFrame_xh
  34. #include <Frame.xh>
  35. #endif
  36.  
  37. #ifndef SOM_ODFrameFacetIterator_xh
  38. #include <FrFaItr.xh>
  39. #endif
  40.  
  41. #ifndef SOM_ODArbitrator_xh
  42. #include <Arbitrat.xh>
  43. #endif
  44.  
  45. #ifndef SOM_Module_OpenDoc_Foci_defined
  46. #include <Foci.xh>
  47. #endif
  48.  
  49. #ifndef SOM_ODShape_xh
  50. #include <Shape.xh>
  51. #endif
  52.  
  53. #ifndef SOM_Module_OpenDoc_StdProps_defined
  54. #include <StdProps.xh>
  55. #endif
  56.  
  57. #ifndef SOM_Module_OpenDoc_StdTypes_defined
  58. #include <StdTypes.xh>
  59. #endif
  60.  
  61. #ifndef SOM_Module_OpenDoc_StdDefs_defined
  62. #include <StdDefs.xh>
  63. #endif
  64.  
  65. #ifndef SOM_Module_OpenDoc_Commands_defined
  66. #include <CmdDefs.xh>
  67. #endif
  68.  
  69. #ifndef SOM_ODDraft_xh
  70. #include <Draft.xh>
  71. #endif
  72.  
  73. #ifndef SOM_ODStorageUnit_xh
  74. #include <StorageU.xh>
  75. #endif
  76.  
  77. #ifndef SOM_ODStorageUnitView_xh
  78. #include <SUView.xh>
  79. #endif
  80.  
  81. #ifndef SOM_ODTransform_xh
  82. #include <Trnsform.xh>
  83. #endif
  84.  
  85. #ifndef SOM_ODFocusSet_xh
  86. #include <FocusSet.xh>
  87. #endif
  88.  
  89. #ifndef SOM_ODMenuBar_xh
  90. #include <MenuBar.xh>
  91. #endif
  92.  
  93. #ifndef SOM_ODWindow_xh
  94. #include <Window.xh>
  95. #endif
  96.  
  97. #ifndef SOM_ODWindowState_xh
  98. #include <WinStat.xh>
  99. #endif
  100.  
  101. #ifndef SOM_ODCanvas_xh
  102. #include <Canvas.xh>
  103. #endif
  104.  
  105. #ifndef SOM_ODSession_xh
  106. #include <ODSessn.xh>
  107. #endif
  108.  
  109.  
  110. struct tsmUtlRec {
  111.     ODBoolean        fHaveTSMTE;
  112.     ODBoolean        fHaveShareTSMlib;
  113.     TEHandle        fTEHandle;
  114.     TSMTERecHandle    fTSMTEHandle;
  115.     TSMDocumentID    fTSMDocID;
  116.     Str255            fText;
  117. };
  118. typedef struct tsmUtlRec tsmUtlRec;
  119.  
  120. void tsmIdle(Environment*, tsmUtlRec*);
  121. void tsmCheck(tsmUtlRec *);
  122. #ifndef USE_CFOCUS
  123. void tsmDraw(Environment*, tsmUtlRec*, ODFacet*);
  124. #else
  125. void tsmDraw(Environment*, tsmUtlRec*, ODFacet*, ODShape*);
  126. #endif
  127. void tsmOpen(Environment*, tsmUtlRec*, ODFrame*);
  128. void tsmClose(Environment*, tsmUtlRec*, ODFrame*);
  129. void tsmKey(Environment*, tsmUtlRec*, ODFrame*, ODEventData*);
  130. void tsmClick(Environment*, tsmUtlRec*, ODFacet*, Point*, ODEventData*);
  131.  
  132. #define TEIDLETICKS 30
  133. #define FontSize 12
  134. #define FontKind 1
  135.